<div id="job_actions">
    <h3>Admin</h3>
    <ul>
    {% if not job.isActivated %}
        <li><a href="{{ path('ens_job_edit', { 'token': job.token }) }}">Edit</a></li>
        <li>
            <form action="{{ path('ens_job_publish', { 'token': job.token }) }}" method="post">
      {{ form_widget(publish_form) }}
                <button type="submit">Publish</button>
            </form>
        </li>
    {% endif %}
        <li>
            <form action="{{ path('ens_job_delete', { 'token': job.token }) }}" method="post">
        {{ form_widget(delete_form) }}
                <button type="submit" onclick="if (!confirm('Are you sure?')) {
                            return false;
                        }">Delete</button>
            </form>
        </li>
    {% if job.isActivated %}
        <li {% if job.expiresSoon %} class="expires_soon" {% endif %}>
        {% if job.isExpired %}
            Expired
        {% else %}
            Expires in <strong>{{ job.getDaysBeforeExpires }}</strong> days
        {% endif %}

        {% if job.expiresSoon %}
            - <a href="">Extend</a> for another 30 days
        {% endif %}
        </li>
    {% else %}
        <li>
            [Bookmark this <a href="{{ url('ens_job_preview', { 'token': job.token, 'company': job.companyslug, 'location': job.locationslug, 'position': job.positionslug }) }}">URL</a> to manage this job in the future.]
        </li>
    {% endif %}
    </ul>
</div>